package com.zlll.winner.business.service.advertising;

import com.alibaba.fastjson.JSONArray;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.zlll.winner.business.model.advertising.AdvertisingPublish;
import com.baomidou.mybatisplus.extension.service.IService;
import com.zlll.winner.business.model.sysUser.SysUser;

import java.util.Map;

/**
 * <p>
 * 广告发布表
 服务类
 * </p>
 *
 * @author qsx
 * @since 2019-09-07
 */
public interface IAdvertisingPublishService extends IService<AdvertisingPublish> {

    Object search(String cityName, Integer type);

    IPage<Map<String, Object>> findAdvertisePage(Long spaceId, Integer status, String cityCode, Integer type, Integer category, Integer pageNo, Integer pageSize);

    boolean addAdPublish(AdvertisingPublish ad, JSONArray details, JSONArray citys, SysUser user);

    int deleteAdVertise(Long id, String name);

    int updateAdvertiseStatus(Long id, int status, SysUser user);

    Object getPublishTree(Long id);

    void editAdPublish(AdvertisingPublish ad, JSONArray details, JSONArray citys, SysUser user);

    Object searchCarousel(String cityName, Integer type);
}
